<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml"
	  xmlns:h="http://java.sun.com/jsf/html"
	  xmlns:f="http://java.sun.com/jsf/core"
	  xmlns:c="http://java.sun.com/jsp/jstl/core"
	  xmlns:p="http://primefaces.org/ui"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:spring="http://www.springframework.org/tags">
      
<f:view contentType="text/html">
	<div class="left-column">
		
		<!-- <h:commandLink value="Lista empleados" action="listaempleados" /> -->
		<h:form>
		<p:menu style="width:160px !important;font-size:0.8em;" >  
	           
	            <p:menuitem value="Lista empleados" actionListener2="#{menuBean.save}" action="listaempleados" update=":growlMessages" ajax="false" icon="ui-icon-disk" />  
	            <p:menuitem value="Lista coches" actionListener2="#{menuBean.save}" action="reviewCars" update=":growlMessages" ajax="false" icon="ui-icon-disk" />
	            <p:menuitem value="Hoteles" actionListener2="#{menuBean.save}" action="enterSearchCriteria" update=":growlMessages" ajax="false" icon="ui-icon-disk" />
	           <ui:remove>
	            <p:menuitem value="Personas" actionListener2="#{menuBean.save}" action="listapersons" update=":growlMessages" ajax="false" icon="ui-icon-disk" />
	   			</ui:remove>
	    </p:menu>  
	
	<ui:remove>	
		 <p:tree value="#{treeBean.root}" var="node" id="tree" 
		 	rendered="${not empty currentUser.name}"
		 	selectionMode="single"  
            selection="#{treeBean.selectedNode}"  
            nodeSelectListener="#{treeBean.onNodeSelect}" 
		 	style="width:160px !important;font-size:0.8em;">  
	        <p:ajax event="select" update=":growlMessages" listener="#{treeBean.onNodeSelect}" />   
	        <p:treeNode id="treeNode" >  
	            <h:outputText value="#{node}" id="lblNode"/>
	        </p:treeNode>  
	    </p:tree>
	     <p:commandButton value="Display Selected" update=":growlMessages"  
                    actionListener="#{treeBean.displaySelectedSingle}" id="btnDisplay"/>  
	 </ui:remove>
	   
	 </h:form>
	</div>
</f:view>
</html>